<div id="inseratListing">
    <table>
        <thead>
            <tr>
                <td class="botBorder" width="100"></td><td class="botBorder" width="100%"></td>
            </tr>
        </thead>
        <tbody>
        {foreach from=$inserats item=inserat}
            <tr>
                <td class="botBorder">
                    {if $inserat.image == 't'}
                        <div class="pict">
                            <img src="/files/inserats/{$inserat.intime|date_format:"%Y/%m/%d/"}{$inserat.id}/thumb.jpg" alt="{#thumbImage#}" />
                        </div>
                    {else}
                        <div class="nopict">
                            {#noPict#}
                        </div>
                    {/if}</td>
                <td class="botBorder">
                    <h4><a href="/{$inserat.url}">{$inserat.title}</a></h4>
                    <p>{$inserat.content|truncate:128|strip_tags}</p>
                    <p><strong>{#price#}: </strong>
                        {if $inserat.price_type == 0}
                            {$inserat.price} {#curr#}
                        {elseif $inserat.price_type == 1}
                            {#bestOffer#}
                        {elseif $inserat.price_type == 2}
                            {#contact#}
                        {elseif $inserat.price_type == 3}
                            {#exchange#}
                        {elseif $inserat.price_type == 4}
                            {#free#}
                        {/if} 
                       <strong>{#type#}:</strong> {if $inserat.type == 1}{#selling#}{else}{#seeking#}{/if}
                    </p>
                </td>
            </tr>
        {foreachelse}
            <tr><td colspan="2" class="botBorder">
                
                {if $action == 'ifolder.html'}
                    <p>{#noJoy#}</p>
    				<p>{#todo#}:</p>
    				<ul>
    					{if $breadcrumbs|@count > 2}
    						{math equation="x-2" assign="myIndex" x=$breadcrumbs|@count}
    						<li>{#tryto#} <a href="{$breadcrumbs[$myIndex].url}">{#levelup#}</a> {#incl#}</li>
    					{/if}
    					
    					{if $smarty.session.filter}
    						<li>{#tryto#} <a href="{$INA.this}?filter=none">{#removedf#}</a> {#youset#}</li>
    					{/if}
    
    					<li>{#tryto#} <a href="{$INA.this}?add=true&type=2">{#addnew2#}</a> {#tothecat#}</li>
    				</ul>
				{else}
				    <p>{#noSearchJoy#}</p>
				    <p>{#tryto#}</p>
				    <ul>
				        <li>{#dos1#}</li>
						<li>{#dos2#}</li>
				        {if $breadcrumbs|@count > 3}
				            {math equation="x-3" assign="myIndex" x=$breadcrumbs|@count}
				            <li>{#sin#} <a href="{$breadcrumbs[$myIndex].url}?search={$smarty.get.search}">{#pfol#}</a></li>
				        {/if}
				        
				        {if $breadcrumbs|@count > 2}
				            <li>{#sin#} <a href="{$INA.root}?search={$smarty.get.search}">{#wholesite#}</a></li>
				        {/if}
				    </ul>
				{/if}
            </td></tr>
        {/foreach}
        </tbody>
    </table>
    
    {if $pager}
        {include file=pager.html}
    {/if}
</div>